Previous Book Contents Book Index Next

Inside Macintosh: QuickDraw GX Objects /
Chapter 7 - View-Related Objects / View-Related Objects Reference
View Port Functions / Manipulating View Port Object Properties


GXSetViewPortViewGroup

You can use the GXSetViewPortViewGroup function to assign a view port object to a new view group.

void GXSetViewPortViewGroup(gxViewPort target, gxViewGroup group);
target
A reference to the view port whose view group you wish to change.
group
A reference to the view group to which the view port is to be assigned.
DESCRIPTION
The GXSetViewPortViewGroup function assigns the target view port to the specified view group. Child view ports of the target view port are also assigned to that view group.

To assign a view port to the onscreen view group, pass the value gxScreenViewDevices for the group parameter. To obtain an offscreen view
group reference to pass to this function, use the GXNewViewGroup function.

SPECIAL CONSIDERATIONS
The view ports in a hierarchy must all be in the same view group.

You cannot change the view group of a window view port (one attached to a Macintosh window).

ERRORS, WARNINGS, AND NOTICES
Errors 
invalid_viewPort_reference 
invalid_viewGroup_reference 
viewPort_is_a_window(debugging version)
Notices (debugging version) 
viewPort_already_in_viewGroup 
SEE ALSO
For an example of the use of this function, see Listing 7-2 on page 7-44.

To get a view port's view group, use the GXGetViewPortViewGroup function, described in the previous section.

The gxScreenViewDevices view group reference is described in the section "View Group Types" on page 7-69.

The GXNewViewGroup function is described on page 7-122.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996